﻿<Window x:Class="PhotoCapture.OptionsBox"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="Options" Height="434" Width="300"
        WindowStyle="SingleBorderWindow"
        Icon="Tools-2.ico"
        Loaded="Window_Loaded_1" Background="Honeydew">
    <Window.Resources>
        <Style x:Key="ButtonStyler" TargetType="{x:Type Button}">
            <Setter Property="Background">
                <Setter.Value>
                    <RadialGradientBrush>
                        <RadialGradientBrush.GradientStops>
                            <GradientStopCollection>
                                <GradientStop Color="black" Offset="0" />
                                <GradientStop Color="black" Offset="1" />
                            </GradientStopCollection>
                        </RadialGradientBrush.GradientStops>
                    </RadialGradientBrush>
                </Setter.Value>
            </Setter>
            <Setter Property="Height" Value="40" />
            <Setter Property="Foreground" Value="Black" />
            <Setter Property="Grid.Row" Value="2" />
            <Setter Property="Grid.Column" Value="3" />
            <Setter Property="Content" Value="Forgot your password?" />
            <Setter Property="ContentTemplate"
                    Value="{DynamicResource myContentTemplate}" />
            <Setter Property="Margin" Value="3" />
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type Button}">
                        <Grid>
                            <Rectangle x:Name="GelBackground"
                                    Opacity="1"
                                    RadiusX="9"
                                    RadiusY="9"
                                    Fill="{TemplateBinding Background}"
                                    StrokeThickness="0.35">
                                <Rectangle.Stroke>
                                    <LinearGradientBrush StartPoint="0,0"
                                            EndPoint="0,1">
                                        <LinearGradientBrush.GradientStops>
                                            <GradientStopCollection>
                                                <GradientStop Color="white"
                                                        Offset="0" />
                                                <GradientStop Color="#666666"
                                                        Offset="1" />
                                            </GradientStopCollection>
                                        </LinearGradientBrush.GradientStops>
                                    </LinearGradientBrush>
                                </Rectangle.Stroke>
                            </Rectangle>
                            <Rectangle x:Name="GelShine"
                        Margin="2,2,2,0"
                        VerticalAlignment="top"
                        RadiusX="6"
                        RadiusY="6"
                        Opacity="1"
                        Stroke="transparent"
                        Height="15px">
                                <Rectangle.Fill>
                                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                                        <LinearGradientBrush.GradientStops>
                                            <GradientStopCollection>
                                                <GradientStop Color="#ccffffff" 
                                                Offset="0" />
                                                <GradientStop Color="transparent"
                                                Offset="1" />
                                            </GradientStopCollection>
                                        </LinearGradientBrush.GradientStops>
                                    </LinearGradientBrush>
                                </Rectangle.Fill>
                            </Rectangle>
                            <ContentPresenter x:Name="GelButtonContent"
                                    VerticalAlignment="center"
                                    HorizontalAlignment="center"
                                    Content="{TemplateBinding Content}" />
                        </Grid>
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsMouseOver" Value="true">
                                <Setter Property="Fill" TargetName="GelBackground">
                                    <Setter.Value>
                                        <RadialGradientBrush>
                                            <RadialGradientBrush.GradientStops>
                                                <GradientStopCollection>
                                                    <GradientStop Color="lime"
                                                            Offset="0" />
                                                    <GradientStop Color="DarkGreen"
                                                            Offset="1" />
                                                </GradientStopCollection>
                                            </RadialGradientBrush.GradientStops>
                                        </RadialGradientBrush>
                                    </Setter.Value>
                                </Setter>
                            </Trigger>
                            <Trigger Property="IsPressed" Value="true">
                                <Setter Property="Fill" TargetName="GelBackground">
                                    <Setter.Value>
                                        <RadialGradientBrush>
                                            <RadialGradientBrush.GradientStops>
                                                <GradientStopCollection>
                                                    <GradientStop Color="#ffcc00"
                                                            Offset="0" />
                                                    <GradientStop Color="#cc9900"
                                                            Offset="1" />
                                                </GradientStopCollection>
                                            </RadialGradientBrush.GradientStops>
                                        </RadialGradientBrush>
                                    </Setter.Value>
                                </Setter>
                            </Trigger>
                        </ControlTemplate.Triggers>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Style.Triggers>
                <Trigger Property="IsMouseOver" Value="true">
                    <Setter Property="Foreground" Value="black " />
                </Trigger>
                <Trigger Property="IsPressed" Value="true">
                    <Setter Property="Foreground" Value="black " />
                </Trigger>
            </Style.Triggers>
        </Style>
        <Style TargetType="TextBox">
            <Setter Property="Width" Value="60" />
        </Style>               
    </Window.Resources>
    <DockPanel Margin="20" Background="Honeydew">
        <GroupBox Header="General" DockPanel.Dock="Top">
            <StackPanel Orientation="Vertical">
                <StackPanel Orientation="Horizontal" IsEnabled="False">
                    <CheckBox Content="Graphic" Margin="5" x:Name="chkGraphics"/>
                    <CheckBox Content="PDF"  Margin="5" x:Name="chkPDF"/>
                    <CheckBox Content="PDF File"  Margin="5" x:Name="chkPDFFile" />
                </StackPanel>
                <StackPanel Orientation="Horizontal">
                    <TextBlock Text="Graphic Type"  Margin="5"/>
                    <ComboBox x:Name="cmbGType" Margin="5">
                    </ComboBox>
                </StackPanel>
                <CheckBox Content="Constrained Capture" Margin="5" Name="chkConstrained"/>
                <CheckBox x:Name="chkWatermarking" Content="Use Watermarking"  Margin="5" Checked="chkWatermarking_Checked_1" Unchecked="chkWatermarking_Checked_1"/>
            </StackPanel>
        </GroupBox>
        <Expander Header="Image Parameters" DockPanel.Dock="Top" IsExpanded="True">
            <StackPanel Orientation="Vertical">
                <StackPanel Orientation="Horizontal">
                    <TextBlock Text="Width" Margin="5"/>
                    <TextBox x:Name="tbWidth" Margin="5" PreviewTextInput="tbNumeric_PreviewTextInput_1"/>
                    <TextBlock Text="Height" Margin="5"/>
                    <TextBox x:Name="tbHeight" Margin="5" PreviewTextInput="tbNumeric_PreviewTextInput_1"/>
                </StackPanel>
                <StackPanel Orientation="Horizontal">
                    <TextBlock Text="Destination Path"  Margin="5" />
                    <TextBox x:Name="tbDestinationPath" Margin="5" IsReadOnly="True" />
                    <Button Style="{StaticResource ButtonStyler}" Height="20" Width="20" Click="Button_Click_3">
                        <Button.Background>
                            <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                                <GradientStop Color="#FF58A4C9" Offset="0.0" />
                                <GradientStop Color="#FF5B8CA4" Offset="0.5" />
                                <GradientStop Color="#FF50BDF3" Offset="0.9" />
                            </LinearGradientBrush>
                        </Button.Background>
                        <TextBlock Text="..." VerticalAlignment="Center" Foreground="AliceBlue" />
                    </Button>
                </StackPanel>
                <StackPanel Orientation="Horizontal">
                        <TextBlock Text="Destination FileName"  Margin="5"/>
                    <TextBox x:Name="tbDestinationFile" Margin="5"/>
                </StackPanel>
                <StackPanel Orientation="Horizontal">
                    <TextBlock Text="Source FileName"  Margin="5"/>
                    <TextBox x:Name="tbSourceFile" Margin="5" IsEnabled="{Binding ElementName=chkPDFFile, Path=IsChecked}"/>
                </StackPanel>
            </StackPanel>
        </Expander>
        <Expander IsExpanded="{Binding ElementName=chkWatermarking, Path=IsChecked}" Header="Watermarking Parameters" DockPanel.Dock="Top">
            <StackPanel Orientation="Vertical">
                <StackPanel Orientation="Horizontal">
                    <TextBlock Text="Text" Margin="5"/>
                    <TextBox x:Name="tbWMText" Margin="5"/>
                    <TextBlock Text="Font" Margin="5"/>
                    <TextBox x:Name="tbFont" Margin="5"/>
                </StackPanel>
                <StackPanel Orientation="Horizontal">
                    <TextBlock Text="Size" Margin="5"/>
                    <TextBox x:Name="tbFontSize" Margin="5" PreviewTextInput="tbNumeric_PreviewTextInput_1"/>
                    <TextBlock Text="Color" Margin="5"/>
                    <TextBox x:Name="tbFontColor" Margin="5"/>
                </StackPanel>
                <StackPanel Orientation="Horizontal">
                    <TextBlock Text="Opacity" Margin="5"/>
                    <TextBox x:Name="tbOpacity" Margin="5"/>
                </StackPanel>
                <StackPanel Orientation="Horizontal">
                    <CheckBox Content="Italic?"  Margin="5" Name="chkItalic"/>
                    <CheckBox Content="Bold?" Margin="5" Name="chkBold"/>
                    <CheckBox Content="Underline?" Margin="5" Name="chkUnderline"/>
                </StackPanel>
                <StackPanel Orientation="Horizontal">
                    <StackPanel Orientation="Horizontal">
                        <TextBlock Text="Left" Margin="5"/>
                        <TextBox x:Name="tbWMLeft" Margin="5" PreviewTextInput="tbNumeric_PreviewTextInput_1"/>
                    </StackPanel>
                    <StackPanel Orientation="Horizontal">
                        <TextBlock Text="Top" Margin="5"/>
                        <TextBox x:Name="tbWMTop" Margin="5" PreviewTextInput="tbNumeric_PreviewTextInput_1"/>
                    </StackPanel>
                </StackPanel>
            </StackPanel>
        </Expander>
        <StackPanel Orientation="Horizontal">
            <Button Click="Button_Click_1" Margin="5" Style="{StaticResource ButtonStyler}" MinHeight="40" MinWidth="80">
                <Button.Background>
                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                        <GradientStop Color="#FF58A4C9" Offset="0.0" />
                        <GradientStop Color="#FF5B8CA4" Offset="0.5" />
                        <GradientStop Color="#FF50BDF3" Offset="0.9" />
                    </LinearGradientBrush>
                </Button.Background>
                <TextBlock Text="Save" VerticalAlignment="Center" Foreground="AliceBlue" />
            </Button>
            <Button Click="Button_Click_2"  MinWidth="80" Margin="5" Style="{StaticResource ButtonStyler}" MinHeight="40">
                <Button.Background>
                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                        <GradientStop Color="#FF58A4C9" Offset="0.0" />
                        <GradientStop Color="#FF5B8CA4" Offset="0.5" />
                        <GradientStop Color="#FF50BDF3" Offset="0.9" />
                    </LinearGradientBrush>
                </Button.Background>
                <TextBlock Text="Close" VerticalAlignment="Center" Foreground="AliceBlue" />
            </Button>
        </StackPanel>
    </DockPanel>
    <!--<Grid Margin="20" Background="Honeydew">
        <Grid.RowDefinitions>
            <RowDefinition />
            <RowDefinition />
            <RowDefinition />
            <RowDefinition />
            <RowDefinition />
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition />
            <ColumnDefinition />
        </Grid.ColumnDefinitions>
        <TextBlock Text="Image Path" Margin="5" />
        <StackPanel Orientation="Horizontal" Grid.Row="0" Grid.Column="1" Margin="5" >
            <TextBox x:Name="imgPath" IsReadOnly="True" Width="90"/>
            <Button Style="{StaticResource ButtonStyler}" Height="20" Width="20" Click="Button_Click_3">
                <Button.Background>
                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                        <GradientStop Color="#FF58A4C9" Offset="0.0" />
                        <GradientStop Color="#FF5B8CA4" Offset="0.5" />
                        <GradientStop Color="#FF50BDF3" Offset="0.9" />
                    </LinearGradientBrush>
                </Button.Background>
                <TextBlock Text="..." VerticalAlignment="Center" Foreground="AliceBlue" />
            </Button>
        </StackPanel>
        <TextBlock Text="Image Width"  Grid.Row="1" Margin="5"/>
        <TextBox x:Name="imgWidth" Grid.Column="1" Grid.Row="1" Margin="5" />
        <TextBlock Text="Image Height"  Grid.Row="2" Margin="5"/>
        <TextBox x:Name="imgHeight" Grid.Column="1" Grid.Row="2" Margin="5"/>
        <TextBlock Text="Database Path"  Grid.Row="3" Margin="5" />
        <StackPanel Orientation="Horizontal" Grid.Column="1" Grid.Row="3" Margin="5" >
            <TextBox x:Name="dbPath" IsReadOnly="True" Width="90"/>
            <Button Style="{StaticResource ButtonStyler}" Height="20" Width="20" Click="Button_Click_4">
                <Button.Background>
                    <LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
                        <GradientStop Color="#FF58A4C9" Offset="0.0" />
                        <GradientStop Color="#FF5B8CA4" Offset="0.5" />
                        <GradientStop Color="#FF50BDF3" Offset="0.9" />
                    </LinearGradientBrush>
                </Button.Background>
                <TextBlock Text="..." VerticalAlignment="Center" Foreground="AliceBlue" />
            </Button>
        </StackPanel>
        <CheckBox x:Name="chkConstraint" Margin="5" Checked="CheckBox_Checked_1" Unchecked="CheckBox_Checked_1" Content="Un constrained"  Grid.Row="4"/>
        <CheckBox x:Name="chkProportional" Margin="5" Checked="CheckBox_Checked_2" Unchecked="CheckBox_Checked_2" Content="Proportional"  Grid.Row="4" Grid.Column="1"/>
 

    </Grid>-->
</Window>
